<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        .masonry {
            column-count: 6;
            column-gap: 0;
        }

        .item {
            box-sizing: border-box;
            break-inside: avoid;
            padding: 10px;
            counter-increment: item-counter;
        }

        .item__content {
            position: relative;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            height: 220px;
            font-size: 40px;
            background: currentColor;
            box-sizing: border-box;
            color: #720026;
        }

        .item__content--small {
            color: #CE4257;
            height: 100px;
        }

        .item__content--medium {
            color: #FFC093;
            height: 175px;
        }

        .item__content--large {
            color: #FF7F51;
            height: 280px;
        }
    </style>
</head>
<body>
<div class="masonry">
    <div class="item">
        <div class="item__content">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--medium">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--medium">
        </div>
    </div>
    <div class="item">
        <div class="item__content">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--large">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--medium">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
    <div class="item">
        <div class="item__content">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--large">
        </div>
    </div>
    <div class="item">
        <div class="item__content">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--large">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--medium">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--medium">
        </div>
    </div>
    <div class="item">
        <div class="item__content">
        </div>
    </div>
    <div class="item">
        <div class="item__content item__content--small">
        </div>
    </div>
</div>
</body>
</html>
